import request from '../util/request'
export const addAdvRequest = (myForm) => {
  return request.post('/addAdv', myForm)
}

export const advListRequest = () => {
  return request.get('/advList')
}

export const deleteAdvRequest = (_id) => {
  return request.delete('/deleteAdv', _id)
}

//点击获取更新按钮所在的行的文件信息
export const getUpdateDataRequest = (_id) => {
  return request.get('/getUpdateData', {
    params: {
      _id
    }
  })
}

export const updateAdvRequest = (formData,_id) =>{
  return request.put('/updateAdv',formData,{
    params:{
      _id
    }
  })
}